Skip to content

Conversation

@EmilHvitfeldt
Copy link
Member

No description provided.

@juliasilge
Copy link
Member

Here are the error messages after the corrections in this PR:

library(parsnip)

set_new_model("potato")
set_model_mode(model = "potato", mode = "classification")

set_fit(
  model = "potato",
  eng = "potato",
  mode = "classification",
  value = list(
    interface = "formula",
    protect = c("formula", "data"),
    func = c(pkg = "potato", fun = "potato"),
    defaults = list()
  )
)
#> Error: The combination of 'potato' and mode 'classification' has not been registered for model 'potato'.
#> Backtrace:
#>     █
#>  1. └─parsnip::set_fit(...)

set_model_engine(
  "potato", 
  mode = "classification", 
  eng = "potato"
)

set_dependency("potato", eng = "potato")
#> Error: Please supply a single character value for the package name.
#> Backtrace:
#>     █
#>  1. └─parsnip::set_dependency("potato", eng = "potato")
#>  2.   └─parsnip:::check_pkg_val(pkg) /Volumes/Data1TB/Google Drive/data_science/rstudio/parsnip/R/aaa_models.R:522:2

set_fit(
  model = "potato",
  eng = "potato",
  mode = "classification",
  value = list(
    interface = "formula",
    protect = c("formula", "data"),
    func = c(pkg = "potato", fun = "potato"),
    defaults = list()
  )
)

set_fit(
  model = "potato",
  eng = "potato",
  mode = "classification",
  value = list(
    interface = "formula",
    protect = c("formula", "data"),
    func = c(pkg = "potato", fun = "potato"),
    defaults = list()
  )
)
#> Error: The combination of 'potato' and mode 'classification' already has a fit component for model 'potato'.
#> Backtrace:
#>     █
#>  1. └─parsnip::set_fit(...)

Created on 2020-08-18 by the reprex package (v0.3.0.9001)

@juliasilge juliasilge merged commit 21f0bb2 into tidymodels:master Aug 18, 2020
@github-actions
Copy link
Contributor

github-actions bot commented Mar 6, 2021

This pull request has been automatically locked. If you believe you have found a related problem, please file a new issue (with a reprex: https://reprex.tidyverse.org) and link to this issue.

@github-actions github-actions bot locked and limited conversation to collaborators Mar 6, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants